﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin.Master" AutoEventWireup="true" CodeBehind="AdminSignUpStaff.aspx.cs" Inherits="TeamNitro.AdminSignUpStaff" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContentHolder" runat="server">
    <style type="text/css">
        .style1
        {
            width: 320px;
        }
        .style2
        {
            width: 152px;
        }
        .style4
        {
            height: 36px;
        }
        .style5
        {
            width: 320px;
            height: 36px;
        }
        .style6
        {
            height: 102px;
        }
        .style7
        {
            width: 320px;
            height: 102px;
        }
        .style8
        {
            height: 44px;
        }
        .style9
        {
            width: 320px;
            height: 44px;
        }
        .style10
        {
            height: 37px;
        }
        .style11
        {
            width: 320px;
            height: 37px;
        }
        .style12
        {
            height: 33px;
        }
        .style13
        {
            width: 320px;
            height: 33px;
        }
        .style14
        {
            height: 39px;
        }
        .style15
        {
            width: 320px;
            height: 39px;
        }
        .style16
        {
        }
        .style17
        {
            height: 39px;
            width: 152px;
        }
        .style18
        {
            height: 33px;
            width: 152px;
        }
        .style19
        {
            height: 37px;
            width: 152px;
        }
        .style20
        {
            height: 44px;
            width: 152px;
        }
        .style21
        {
            height: 102px;
            width: 152px;
        }
        .style22
        {
            height: 36px;
            width: 152px;
        }
        .style23
        {
            width: 40px;
        }
        .style24
        {
            height: 30px;
            width: 40px;
        }
        .style25
        {
            height: 39px;
            width: 40px;
        }
        .style26
        {
            height: 33px;
            width: 40px;
        }
        .style27
        {
            height: 37px;
            width: 40px;
        }
        .style28
        {
            height: 44px;
            width: 40px;
        }
        .style29
        {
            height: 102px;
            width: 40px;
        }
        .style30
        {
            height: 36px;
            width: 40px;
        }
        </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContentHolder" runat="server">
    <table style="width:100%;">
        <tr>
            <td class="style23">
                &nbsp;</td>
            <td colspan="3">
                <h2>
                    <asp:Label ID="Label1" runat="server" Text="Create Staff Account"></asp:Label>
                </h2>
            </td>
        </tr>
        <tr>
            <td class="style24">
                    &nbsp;</td>
            <td class="style16" colspan="3">
                    <asp:Label ID="lblResult" runat="server" ForeColor="#00CC00" Visible="False"></asp:Label>
            </td>
        </tr>
        <tr>
            <td class="style24">
                    &nbsp;</td>
            <td class="style16" colspan="3">
                    *Required Field</td>
        </tr>
        <tr>
            <td class="style25">
                &nbsp;</td>
            <td class="style17">
                Staff ID*<br />
            </td>
            <td class="style15">
        <asp:TextBox runat="server" Width="300px" ID="tbxStaffID"></asp:TextBox>

                    <br />
                <asp:RegularExpressionValidator ID="revStaffID" runat="server" 
                    ControlToValidate="tbxStaffID" 
                    
                    
                    ErrorMessage="Starts with &quot;6&quot; Digits and Ends with &quot;1&quot; Alphabetic" ForeColor="#FF3300" 
                    ValidationExpression="[0-9]{6}[A-Za-z]$"></asp:RegularExpressionValidator>
            </td>
            <td class="style14">
                    <asp:RequiredFieldValidator runat="server" ForeColor="#FF3300" 
            ControlToValidate="tbxStaffID" ErrorMessage="Required ID" Display="Dynamic" 
            ID="rfvStaffId"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td class="style26">
                &nbsp;</td>
            <td class="style18">
                Name*</td>
            <td class="style13">
        <asp:TextBox runat="server" Width="300px" ID="tbxStaffName"></asp:TextBox>

                    </td>
            <td class="style12">
                    <asp:RequiredFieldValidator runat="server" ForeColor="#FF3300" 
            ControlToValidate="tbxStaffName" ErrorMessage="Required Name" Display="Dynamic" 
            ID="rfvStaffName"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td class="style27">
                &nbsp;</td>
            <td class="style19">
                Password*</td>
            <td class="style11">
                <asp:TextBox 
            runat="server" TextMode="Password" Width="300px" ID="tbxStaffPassword"></asp:TextBox>

                    </td>
            <td class="style10">
                    <asp:RequiredFieldValidator runat="server" ForeColor="#FF3300" 
            ControlToValidate="tbxStaffPassword" ErrorMessage="Required Password" 
            Display="Dynamic" ID="rfvStaffPassword"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td class="style28">
                &nbsp;</td>
            <td class="style20">
                Re-enter Password*<br />
            </td>
            <td class="style9">
                <asp:TextBox 
            runat="server" TextMode="Password" Width="300px" ID="tbxStaffRePassword"></asp:TextBox>

                    <br />
        <asp:CompareValidator runat="server" ControlToCompare="tbxStaffPassword" 
            ForeColor="#FF3300" ControlToValidate="tbxStaffRePassword" 
            ErrorMessage="Password not match" ID="cvStaffPassword"></asp:CompareValidator>
            </td>
            <td class="style8">
                    <asp:RequiredFieldValidator runat="server" ForeColor="#FF3300" 
            ControlToValidate="tbxStaffRePassword" 
            ErrorMessage="Required Re-enter Password" Display="Dynamic" 
            ID="rfvStaffRePassword"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td class="style23">
                &nbsp;</td>
            <td class="style2">
                Contact Number*<br />
            </td>
            <td class="style1">
        <asp:TextBox runat="server" Width="300px" ID="tbxStaffContact"></asp:TextBox>

                    <br />
        <asp:RegularExpressionValidator ID="revStaffContact" runat="server" 
                        ControlToValidate="tbxStaffContact" ErrorMessage="Please Only Enter &quot;8&quot; Digits" 
                        ForeColor="#FF3300" ValidationExpression="[0-9]{8}"></asp:RegularExpressionValidator>
            </td>
            <td>
                    <asp:RequiredFieldValidator runat="server" ForeColor="#FF3300" 
            ControlToValidate="tbxStaffContact" ErrorMessage="Required Contact Number" 
            Display="Dynamic" ID="rfvStaffContact"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td class="style29">
                &nbsp;</td>
            <td class="style21">
                Address*</td>
            <td class="style7">
        <asp:TextBox runat="server" TextMode="MultiLine" Height="82px" Width="300px" 
            ID="tbxStaffAddress"></asp:TextBox>

                    </td>
            <td class="style6">
                    <asp:RequiredFieldValidator runat="server" ForeColor="#FF3300" 
            ControlToValidate="tbxStaffAddress" ErrorMessage="Required Address" 
            Display="Dynamic" ID="rfvStaffAddress"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td class="style23">
                &nbsp;</td>
            <td class="style2">
                Email*<br />
                <br />
            </td>
            <td class="style1">
                <br />
                <asp:TextBox 
            runat="server" Width="150px" ID="tbxStaffEmail"></asp:TextBox>

                    &nbsp;<asp:Label ID="lblEmailDomain" runat="server" Text="@staff.tp.edu.sg"></asp:Label>

                    <br />
        <asp:RegularExpressionValidator ID="rexAdminEmail" runat="server" 
            ControlToValidate="tbxStaffEmail" ErrorMessage="RegularExpressionValidator" 
            ForeColor="#FF3300" 
                    ValidationExpression="[0-9]{6}[A-Za-z]$" Width="365px">Enter Valid Email Address (e.g. 123456A@staff.tp.edu.sg)</asp:RegularExpressionValidator>
            </td>
            <td>
                    <asp:RequiredFieldValidator runat="server" ForeColor="#FF3300" 
            ControlToValidate="tbxStaffEmail" ErrorMessage="Required Email" 
            Display="Dynamic" ID="rfvStaffEmail"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td class="style30">
                &nbsp;</td>
            <td class="style22">
                Position*&nbsp;&nbsp;</td>
            <td class="style5">
        <asp:TextBox runat="server" Width="300px" ID="tbxStaffPosition"></asp:TextBox>
            </td>
            <td class="style4">
        <asp:RequiredFieldValidator runat="server" ForeColor="#FF3300" 
            ControlToValidate="tbxStaffPosition" ErrorMessage="Required Position" 
            Display="Dynamic" ID="rfvStaffPosition"></asp:RequiredFieldValidator>
            </td>
        </tr>
        <tr>
            <td class="style30">
                &nbsp;</td>
            <td class="style22">
        School*<br />
                <br />
                <br />
                <br />
                <br />
                <br />
            </td>
            <td class="style5">
                <br />
                <asp:RadioButtonList runat="server" ID="rblStaffSchool">
            <asp:ListItem>School of Informatics and IT</asp:ListItem>
            <asp:ListItem>School of Applied Science</asp:ListItem>
            <asp:ListItem>School of Business</asp:ListItem>
            <asp:ListItem>School of Design</asp:ListItem>
            <asp:ListItem>School of Engineering</asp:ListItem>
            <asp:ListItem>School of Humanities and Social Sciences</asp:ListItem>
        </asp:RadioButtonList>
                <br />
        <asp:RequiredFieldValidator runat="server" ForeColor="#FF3300" 
            ControlToValidate="rblStaffSchool" ErrorMessage="Required School" 
            Display="Dynamic" ID="rfvStaffSchool"></asp:RequiredFieldValidator>
            </td>
            <td class="style4">
                &nbsp;</td>
        </tr>
        <tr>
            <td class="style23">
                &nbsp;</td>
            <td class="style2">
                <br />
        <asp:Button runat="server" Text="Create" Width="90px" ID="btnStaffCreate" 
            OnClick="btnStaffCreate_Click"></asp:Button>
            </td>
            <td class="style1">
                &nbsp;</td>
            <td>
                &nbsp;</td>
        </tr>
    </table>
</asp:Content>
